﻿using UnityEngine;

public class SkeletonIdleState:SkeletonGroundState
{
    public SkeletonIdleState(ControllerBase controller, StateMachineBase stateMachine, 
        string stateName, string animatorParameter = null) : base(controller, stateMachine, stateName, animatorParameter)
    {
    }

    public override void Enter()
    {
        base.Enter();
        SelfController.SetVelocity(Vector2.zero);
    }

    public override void Update()
    {
        base.Update();
        if (stateDuration > SelfController.GetEnemyStateInfo().IdleTime)
        {
            stateMachine.ChangeState(Setting.move);
            return;
        }
        
    }
}